package com.cmbchina.creditcard.domain.model;

import lombok.Data;

import java.math.BigDecimal;

/**
 * 金普卡
 */
@Data
public class GoldCard extends CreditCard{
    private BigDecimal point;
    public GoldCard(String cardType){
        super(cardType, new BigDecimal("5000"));
    }

    @Override
    public Boolean consume(BigDecimal amount) {
        return super.consume(amount);
    }

    @Override
    protected void updatePoints(BigDecimal amount) {
        point = point.add(amount);
    }
}
